<template>
	<view class="conter">

		<!-- <header-box :title="title"></header-box> -->
		
		
		<view class="header" style="color: #000000;" @tap="goBack(id)">
			<view class="arrow">
			</view>
			<view class="title">
				{{title}}
			</view>
		</view>
		
		
		
		

		
			
			
			<view class="flex-box" style="margin-top: 20rpx;padding-left: 30rpx;">
				<view class="left-box" style="display: flex;align-items: center;">
					<view class="left-image">
						<!-- <image src="../../static/image/11.jpg" mode=""></image> -->
						<open-data class="user-avatar" type="userAvatarUrl"></open-data>
					</view>
					<view class="">
						<open-data class="user-name" type="userNickName"></open-data>
					</view>
				</view>
				<navigator :url="'/pages/site/uploadPhone?info='+3" class="money ">
					<view class="money-image">
						<image src="../../static/index/fb.png" mode=""></image>
					</view>
					上传图册
				</navigator>
			</view>
			
			
			
			
			
			<view class="" style="padding: 0 30rpx;">
			
			
			<view class="box-info flex-box">
				<view class="">
					<view class="">
						我的余额(元)
					</view>
					<view class="" style="font-size: 44rpx; margin-top: 16rpx;">
						<text class="text-price"></text>
						<u-count-to :start-val="30" :end-val="1653.00" color="#fff"></u-count-to>
					</view>
				</view>
				<view class="balance">
					余额提现
				</view>
			</view>
			
			<!-- /pages/site/meBuy -->
			<navigator url="/pages/site/listInfo" class="me-shopping flex-box">
				<view class="">
					我购买的
				</view>
				<view class="flex align-center">
					 <view class="">
					      <view class="cu-avatar-group">
					        <view class="cu-avatar round " v-for="(item,index) in 3" :key="index"></view> 
					      </view>
					 </view>
					<text class="cuIcon-right"></text>
				</view>
			</navigator>
		</view>
		
		
		<view class="" style="width: 100%; height: 20rpx; background-color: #F8F8F8;">
			
		</view>
		
	
		<view class="" style="padding: 0 30rpx;">
			 
			 
			 <navigator :url="'/pages/site/hotelInfo?info='+2" class="flex-box box2">
			 	<view class="" style="color: #000000; font-weight: 600;">
			 		正在出售
			 	</view>
			 	<view class="" style="color: #717171; font-size: 26rpx;">
			 		共14件<text class="cuIcon-right" style="margin-left: 6rpx;"></text>
			 	</view>
			 </navigator>
			 
			 
			 <view class="user-info" v-for="(item, index) in list" :key="index">
			 	<view class="flex-box">
			 		<view class="user-info-left">
			 			<view class="user-image">
			 				<image src="../../static/image/11.jpg" mode=""></image>
			 			</view>
			 			<view class="">
			 				<view class="text-cut f28" style="width: 360rpx; white-space: nowrap;margin-bottom: 10rpx;">
			 					成都维纳斯时尚主题酒店公寓
			 				</view>
							<view class="text-cut f26" style="color: #717171;">
								<u-icon name="map" color="#717171"></u-icon>
								成都市金牛区万达广场
							</view>
			 			</view>
			 		</view>
			 		<view class="sold-out">
						已售<text style="margin-left: 6rpx; font-size: 24rpx;">120</text>
			 		</view>
			 	</view>
			 </view>
			 
			 
		</view>



	


	</view>
</template>

<script>
	export default {
		components: {},
		data() {
			return {
				title: '我的',
				count: 4,
				value: 2,
				list: [{
					name: '1111',
					value: 2
				}, {
					name: '3333',
					value: 2
				}],
				img: []
			}
		},

		onLoad() {
			this.img = [
				'https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1711988758,3749142602&fm=15&gp=0.jpg',
				'https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1711988758,3749142602&fm=15&gp=0.jpg',
				'https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1711988758,3749142602&fm=15&gp=0.jpg',
				'https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1711988758,3749142602&fm=15&gp=0.jpg',
				'https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1711988758,3749142602&fm=15&gp=0.jpg',
			]
		},
		onReachBottom() {

		},
		methods: {
			
			goBack(id) {
				console.log(id)
				uni.navigateBack({
				    delta: 1
				})
			},	
			
			

			image() {
				console.log(9999);
				uni.previewImage({
					urls: [...this.img],
					longPressActions: {
						itemList: ['发送给朋友', '保存图片', '收藏'],
						success: function(data) {
							console.log('选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片');
						},
						fail: function(err) {
							console.log(err.errMsg);
						},
					},
				});
			},

			buy() {
				console.log('唤起支付')
				uni.requestPayment({
					provider: 'wxpay',
					timeStamp: String(Date.now()),
					nonceStr: 'A1B2C3D4E5',
					package: 'prepay_id=wx20180101abcdefg',
					signType: 'MD5',
					paySign: '',
					success: function(res) {
						console.log('success:' + JSON.stringify(res));
					},
					fail: function(err) {
						console.log('fail:' + JSON.stringify(err));
					}
				});

			},
			
			// 复制文本
			copy() {
				uni.setClipboardData({
				    data: 'hello',
				    success: function () {
				        console.log('success');
						// this.$tools.msg('复制成功')
				    }
				});
				
				// uni.getClipboardData({
				//     success: function (res) {
				//         console.log(res.data);
				//     }
				// });
			}
		}
	}
</script>

<style lang="scss" scoped>
	.conter {
		width: 100%;
		height: 100%;
		// padding: 0 30rpx;
		background-color: #FFFFFF;

		image {
			width: 100%;
			height: 100%;
		}
		
		
		
		.header {
			width: 100%;
			height: 150rpx;
			line-height: 150rpx;
			display: flex;
			align-items: center;
			// padding-left: 10rpx;
			padding-top: 30rpx;
			font-size: 36rpx;
			font-family: PingFang SC;
			font-weight: 500;
			background: #FFFFFF;
			
			.arrow{
			  position: relative;
			  display: inline-block;
			}
			
			.arrow::before{
			  content: '';
			  width: 10px;
			  height: 10px;
			  border: 0px;
			  border-bottom: solid 2px #2C2C2C;
			  border-left: solid 2px #2C2C2C;
			  -ms-transform: rotate(45deg);
			  -webkit-transform: rotate(45deg);
			  transform: rotate(45deg);
			  position: absolute;
			  top: 50%;
			  left: 0;
			  margin-top: -4px;
			  margin-left: 28rpx;
			}
			
			.title {
				margin: 0 auto;
			}
		}
		
		
		
		

		.left-box {

			.left-image {
				width: 120rpx;
				height: 120rpx;
				margin-right: 20rpx;
				overflow: hidden;
				border-radius: 60rpx !important;

				image {
					width: 100%;
					height: 100%;
					border-radius: 60rpx !important;
				}
			}
		}

		.money {
			width: 228rpx;
			height: 56rpx;
			display: flex;
			padding: 0 33rpx;
			align-items: center;
			border-radius: 25rpx 0 0 25rpx;
			color: #54599B;
			font-size: 28rpx;
			background: RGBA(238, 238, 245, 1);
			
			.money-image {
				width: 30rpx;
				height: 30rpx;
				margin-right: 19rpx;
			}
		}



		.box-info {
			width: 100%;
			height: 138rpx;
			margin-top: 35rpx;
			padding: 0 30rpx;
			color: #FFFFFF;
			background-color: #4F5394;
			border-radius: 16rpx;
			
			.balance {
				width: 198rpx;
				height: 58rpx;
				border-radius: 29rpx;
				line-height: 58rpx;
				text-align: center;
				color: #4F5394;
				font-size: 30rpx;
				background-color: #FFFFFF;
			}
		}
		
		
		
		.me-shopping {
			width: 100%;
			height: 116rpx;
		}



		.box2 {
			width: 100%;
			height: 90rpx;
			color: #717171;
			line-height: 90rpx;
		}


		.user-info {
			width: 100%;
			height: 140rpx;
			// line-height: 100rpx;
			color: #232323;
			display: flex;
			align-items: center;
			border-radius: 10rpx;
			border-bottom: 1rpx solid #F8F8F8;

			.user-info-left {
				display: flex;
				align-items: center;
			}

			.user-image {
				width: 110rpx;
				height: 94rpx;
				border-radius: 10rpx;
				margin-right: 30rpx;

				image {
					border-radius: 10rpx;
				}
			}

			.sold-out {
				width: 160rpx;
				height: 50rpx;
				line-height: 50rpx;
				text-align: center;
				border-radius: 25rpx;
				color: #ECA700;
				background: rgba(236,167,0, .1);
			}
		}
		
		.user-info:last-child {
			border-bottom: 0;
		}

	}
</style>
